
const state = {
  notificationTag: 0,
  notificationChangeTag: 0,
  notificationNum: 0,
  notificationNum_NavMenu: 0, // 菜单栏的消息数量
  notificationId: 0,
  notificationStatus: 0,
  topCommonNoticeType: 0,
  topCommonNoticeId: '',
  topCommonNoticeContent: '',
  repairRecordStatus: ''
}

const mutations = {
  SET_notificationTag: (state, value) => {
    state.notificationTag = value
  },
  SET_notificationNum: (state, value) => {
    state.notificationNum = value
  },
  SET_notificationId: (state, value) => {
    state.notificationId = value
  },
  SET_notificationStatus: (state, value) => {
    console.log('qweqew', value)
    state.notificationStatus = value
  },
  SET_repairRecordStatus: (state, value) => {
    state.repairRecordStatus = value
  }
}

const actions = {
  changeId(context, value) {
    context.commit('SET_notificationId', value)
  },
  changeDataStatus(context, value) {
    context.commit('SET_notificationStatus', value)
  },
  repairRecordStatus(context, value) {
    context.commit('SET_repairRecordStatus', value)
  }
}

export default {
  namespaced: true,
  state,
  mutations,
  actions
}
